<?php
/**
 * Author: 孙武 QQ:1228746736
 * Date: 2018/2/16
 * Time: 10:15
 */


/**
 * 数据状态公共类
 */

namespace app\home\def;
class  Status
{
    private static $dbStatus = [
//        "delete" => ['Status' => '已删除'],
//        'notDelete' => ['Status', 'neq', '已删除'],
//        'notPass' => ["Status" => '未审核'],
//        'pass' => ["Status" => '已审核'],

    ];

    static $pass= ["Status" => '已审核'];
    static $notPass=["Status" => '未审核'];
    static $delete=['Status' => '已删除'];
    static $notDelete=['Status', 'neq', '已删除'];
    static $able=['Status'=>'启用'];
    static $disable=['Status'=>'禁用'];
    static $notQuestion=['Status','neq','问题'];

    /*
     * ENUM('网盘资源', '实体资源', 'URL资源', '文本资源', '问题')
     */
    static $resType=['网盘资源', '实体资源', 'URL资源', '文本资源', '问题'];//资源类型
    static $price=[1,2,3,4,5];//售价


    public static function status($stat = '')
    {
        switch ($stat) {
            case "del":
                return self::$delete;
                break;
            case "delete":
                return self::$delete;
                break;
            case "notDelete":
                return self::$notDelete;
                break;
            case "pass":
                return self::$pass;
                break;
            case "notPass":
                return self::$notPass;
                break;

        }
    }

    public static function getAllStatus()
    {
        return self::$dbStatus;
    }
}